﻿<%@ Page Language="C#" MasterPageFile="~/SiteMasterPage.Master" AutoEventWireup="true" CodeBehind="AddProduct.aspx.cs" Inherits="ASPNETWebApplication.WebShop.AddProduct" Title="Add Product"%>

<%@ Import Namespace="ASPNETWebApplication.ActionServiceReference" %>

<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    Add New Product<asp:DetailsView ID="DetailsView1" runat="server" 
        AutoGenerateRows="False" DataSourceID="ObjectDataSourceProduct" Height="50px" 
        Width="125px">
        <Fields>
            <asp:BoundField DataField="ProductId" HeaderText="ProductId" 
                SortExpression="ProductId" />
            <asp:BoundField DataField="ProductName" HeaderText="ProductName" 
                SortExpression="ProductName" />
            <asp:BoundField DataField="UnitPrice" HeaderText="UnitPrice" 
                SortExpression="UnitPrice" />
            <asp:BoundField DataField="UnitsInStock" HeaderText="UnitsInStock" 
                SortExpression="UnitsInStock" />
            <asp:BoundField DataField="Version" HeaderText="Version" 
                SortExpression="Version" />
            <asp:BoundField DataField="Weight" HeaderText="Weight" 
                SortExpression="Weight" />
        </Fields>
    </asp:DetailsView>
    <asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="Button" />
    <asp:ObjectDataSource ID="ObjectDataSourceProduct" runat="server" 
        DataObjectTypeName="ASPNETWebApplication.ActionServiceReference.Product" 
        InsertMethod="AddProduct" OldValuesParameterFormatString="original_{0}" 
        SelectMethod="GetProduct" 
        TypeName="ASPNETWebApplication.Repositories.ProductRepository">
        <SelectParameters>
            <asp:Parameter Name="productId" Type="Int32" />
        </SelectParameters>
    </asp:ObjectDataSource>
&nbsp;

</asp:Content>
